package com.vast.admin.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.vast.admin.entity.statistics.MyContractStatisticsBean;
import com.vast.admin.entity.statistics.StatisticsByCompanyBean;
import com.vast.admin.mapper.MyContractStatisticsMapper;
import com.vast.admin.mapper.StatisticsMapper;
import com.vast.admin.service.StatisticsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class StatisticsServiceImpl implements StatisticsService {

    @Autowired
    private StatisticsMapper statisticsMapper;

    @Autowired
    private MyContractStatisticsMapper myContractStatisticsMapper;

    @Override
    public IPage<StatisticsByCompanyBean> statisticsContractByCompany(Page<StatisticsByCompanyBean> page, StatisticsByCompanyBean statistics) {
        return statisticsMapper.statisticsContractByCompany(page,statistics);
    }

    @Override
    public IPage<StatisticsByCompanyBean> statisticsContractByDept(Page<StatisticsByCompanyBean> page, StatisticsByCompanyBean statistics) {
        return statisticsMapper.statisticsContractByDept(page,statistics);
    }

    @Override
    public IPage<MyContractStatisticsBean> contractInfoStatisticsPage(Page<MyContractStatisticsBean> page, MyContractStatisticsBean contract) {

        IPage<MyContractStatisticsBean> result = myContractStatisticsMapper.contractInfoStatisticsPage(page,contract);
        return result;
    }
}
